<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>perlpod - the Plain Old Documentation format - Perldoc Browser</title>
    <link rel="search" href="https://perldoc.perl.org/opensearch.xml" type="application/opensearchdescription+xml" title="Perldoc Browser">
    <link rel="canonical" href="https://perldoc.perl.org/perlpod">
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.5.0/styles/stackoverflow-light.min.css" integrity="sha512-cG1IdFxqipi3gqLmksLtuk13C+hBa57a6zpWxMeoY3Q9O6ooFxq50DayCdm0QrDgZjMUn23z/0PMZlgft7Yp5Q==" crossorigin="anonymous" />
    <style>
      body {
        background: #f4f4f5;
        color: #020202;
      }
      .navbar-dark {
        background-image: -webkit-linear-gradient(top, #005f85 0, #002e49 100%);
        background-image: -o-linear-gradient(top, #005f85 0, #002e49 100%);
        background-image: linear-gradient(to bottom, #005f85 0, #002e49 100%);
        filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff005f85', endColorstr='#ff002e49', GradientType=0);
        background-repeat: repeat-x;
      }
      .navbar-dark .navbar-nav .nav-link,
      .navbar-dark .navbar-nav .nav-link:focus { color: #fff }
      .navbar-dark .navbar-nav .nav-link:hover { color: #ffef68 }
      #wrapperlicious {
        margin: 0 auto;
        font: 0.9em 'Helvetica Neue', Helvetica, sans-serif;
        font-weight: normal;
        line-height: 1.5em;
        margin: 0;
        padding: 0;
      }
      #wrapperlicious h1 { font-size: 1.5em }
      #wrapperlicious h2 { font-size: 1.3em }
      #wrapperlicious h3 { font-size: 1.1em }
      #wrapperlicious h4 { font-size: 0.9em }
      #wrapperlicious h1, #wrapperlicious h2, #wrapperlicious h3,
      #wrapperlicious h4, #wrapperlicious dt {
        color: #020202;
        margin-top: 1em;
        margin-bottom: 1em;
        position: relative;
        font-weight: bold;
      }
      #wrapperlicious a { color: inherit; text-decoration: underline }
      #wrapperlicious #toc { text-decoration: none }
      #wrapperlicious a:hover { color: #2a2a2a }
      #wrapperlicious a img { border: 0 }
      #wrapperlicious :not(pre) > code {
        color: inherit;
        background-color: rgba(0, 0, 0, 0.04);
        border-radius: 3px;
        font: 0.9em Consolas, Menlo, Monaco, monospace;
        padding: 0.3em;
      }
      #wrapperlicious dd {
        margin: 0;
        margin-left: 2em;
      }
      #wrapperlicious dt {
        color: #2a2a2a;
        font-weight: bold;
        margin-left: 0.9em;
      }
      #wrapperlicious p {
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious li > p {
        margin-bottom: 0;
        margin-top: 0;
      }
      #wrapperlicious pre {
        border: 1px solid #c1c1c1;
        border-radius: 3px;
        font: 100% Consolas, Menlo, Monaco, monospace;
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious pre > code {
        display: block;
        background-color: #f6f6f6;
        font: 0.9em Consolas, Menlo, Monaco, monospace;
        line-height: 1.5em;
        text-align: left;
        white-space: pre;
        padding: 1em;
      }
      #wrapperlicious dl, #wrapperlicious ol, #wrapperlicious ul {
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious ul {
        list-style-type: square;
      }
      #wrapperlicious ul ul {
        margin-bottom: 0px;
        margin-top: 0px;
      }
      #footer {
        font-size: 0.8em;
        padding-top: 0.5em;
        text-align: center;
      }
      #more {
        display: inline;
        font-size: 0.8em;
      }
      #perldocdiv {
        background-color: #fff;
        border: 1px solid #c1c1c1;
        border-bottom-left-radius: 5px;
        border-bottom-right-radius: 5px;
        margin-left: auto;
        margin-right: auto;
        padding: 3em;
        padding-top: 1em;
        max-width: 960px;
      }
      #moduleversion { float: right }
      #wrapperlicious .leading-notice {
        font-style: italic;
        padding-left: 1em;
        margin-top: 1em;
        margin-bottom: 1em;
      }
      #wrapperlicious .permalink {
        display: none;
        left: -0.75em;
        position: absolute;
        padding-right: 0.25em;
        text-decoration: none;
      }
      #wrapperlicious h1:hover .permalink, #wrapperlicious h2:hover .permalink,
      #wrapperlicious h3:hover .permalink, #wrapperlicious h4:hover .permalink,
      #wrapperlicious dt:hover .permalink {
        display: block;
      }
    </style>
    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=G-KVNWBNT5FB"></script>
    <script>
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());

      gtag('config', 'G-KVNWBNT5FB');
      gtag('config', 'UA-50555-3');
    </script>
  </head>
  <body>
    <nav class="navbar navbar-expand-md navbar-dark bg-dark justify-content-between">
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
  <a class="navbar-brand" href="https://perldoc.perl.org/">Perldoc Browser</a>
  <div class="collapse navbar-collapse" id="navbarNav">
    <ul class="navbar-nav mr-auto">
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="perlpod.html#" id="dropdownlink-stable" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">5.35.0</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-stable">
          <a class="dropdown-item" href="https://perldoc.perl.org/perlpod">Latest</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.2/perlpod">5.38.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.1/perlpod">5.38.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0/perlpod">5.38.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.3/perlpod">5.36.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.2/perlpod">5.36.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.1/perlpod">5.36.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.0/perlpod">5.36.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.3/perlpod">5.34.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.2/perlpod">5.34.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.1/perlpod">5.34.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.0/perlpod">5.34.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.32.1/perlpod">5.32.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.32.0/perlpod">5.32.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.3/perlpod">5.30.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.2/perlpod">5.30.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.1/perlpod">5.30.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.0/perlpod">5.30.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.3/perlpod">5.28.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.2/perlpod">5.28.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.1/perlpod">5.28.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.0/perlpod">5.28.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.3/perlpod">5.26.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.2/perlpod">5.26.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.1/perlpod">5.26.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.0/perlpod">5.26.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.4/perlpod">5.24.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.3/perlpod">5.24.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.2/perlpod">5.24.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.1/perlpod">5.24.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.0/perlpod">5.24.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.4/perlpod">5.22.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.3/perlpod">5.22.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.2/perlpod">5.22.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.1/perlpod">5.22.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.0/perlpod">5.22.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.3/perlpod">5.20.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.2/perlpod">5.20.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.1/perlpod">5.20.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.0/perlpod">5.20.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.4/perlpod">5.18.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.3/perlpod">5.18.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.2/perlpod">5.18.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.1/perlpod">5.18.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.0/perlpod">5.18.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.3/perlpod">5.16.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.2/perlpod">5.16.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.1/perlpod">5.16.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.0/perlpod">5.16.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.4/perlpod">5.14.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.3/perlpod">5.14.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.2/perlpod">5.14.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.1/perlpod">5.14.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.0/perlpod">5.14.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.5/perlpod">5.12.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.4/perlpod">5.12.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.3/perlpod">5.12.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.2/perlpod">5.12.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.1/perlpod">5.12.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.0/perlpod">5.12.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.10.1/perlpod">5.10.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.10.0/perlpod">5.10.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.9/perlpod">5.8.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.8/perlpod">5.8.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.7/perlpod">5.8.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.6/perlpod">5.8.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.5/perlpod">5.8.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.4/perlpod">5.8.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.3/perlpod">5.8.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.2/perlpod">5.8.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.1/perlpod">5.8.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.0/perlpod">5.8.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.2/perlpod">5.6.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.1/perlpod">5.6.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.0/perlpod">5.6.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_04/perlpod">5.005_04</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_03/perlpod">5.005_03</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_02/perlpod">5.005_02</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_01/perlpod">5.005_01</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005/perlpod">5.005</a>
        </div>
      </li>
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="perlpod.html#" id="dropdownlink-dev" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Dev</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-dev">
          <a class="dropdown-item" href="https://perldoc.perl.org/blead/perlpod">blead</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.6/perlpod">5.39.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.5/perlpod">5.39.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.4/perlpod">5.39.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.3/perlpod">5.39.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.2/perlpod">5.39.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.1/perlpod">5.39.1</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0-RC2/perlpod">5.38.0-RC2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0-RC1/perlpod">5.38.0-RC1</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.11/perlpod">5.37.11</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.10/perlpod">5.37.10</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.9/perlpod">5.37.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.8/perlpod">5.37.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.7/perlpod">5.37.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.6/perlpod">5.37.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.5/perlpod">5.37.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.4/perlpod">5.37.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.3/perlpod">5.37.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.2/perlpod">5.37.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.1/perlpod">5.37.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.0/perlpod">5.37.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.11/perlpod">5.35.11</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.10/perlpod">5.35.10</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.9/perlpod">5.35.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.8/perlpod">5.35.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.7/perlpod">5.35.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.6/perlpod">5.35.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.5/perlpod">5.35.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.4/perlpod">5.35.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.3/perlpod">5.35.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.2/perlpod">5.35.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.1/perlpod">5.35.1</a>
          <a class="dropdown-item active" href="perlpod.html">5.35.0</a>
        </div>
      </li>
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="perlpod.html#" id="dropdownlink-nav" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Documentation</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-nav">
          <a class="dropdown-item" href="perl.html">Perl</a>
          <a class="dropdown-item" href="perlintro.html">Intro</a>
          <a class="dropdown-item" href="perl.html#Tutorials">Tutorials</a>
          <a class="dropdown-item" href="perlfaq.html">FAQs</a>
          <a class="dropdown-item" href="perl.html#Reference-Manual">Reference</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="perlop.html">Operators</a>
          <a class="dropdown-item" href="functions.html">Functions</a>
          <a class="dropdown-item" href="variables.html">Variables</a>
          <a class="dropdown-item" href="modules.html">Modules</a>
          <a class="dropdown-item" href="perlutil.html">Utilities</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="perlcommunity.html">Community</a>
          <a class="dropdown-item" href="perlhist.html">History</a>
        </div>
      </li>
    </ul>
    <ul class="navbar-nav">
      <script>
        function set_expand (expand) {
          var perldocdiv = document.getElementById('perldocdiv');
          var width = window.getComputedStyle(perldocdiv).getPropertyValue('max-width');
          var expanded = (width == '' || width == 'none') ? true : false;
          if (expand === null) {
            expand = !expanded;
          }
          if ((expand && !expanded) || (!expand && expanded)) {
            perldocdiv.style.setProperty('max-width', expand ? 'none' : '960px');
            var button_classlist = document.getElementById('content-expand-button').classList;
            if (expand) {
              button_classlist.add('btn-light');
              button_classlist.remove('btn-outline-light');
            } else {
              button_classlist.add('btn-outline-light');
              button_classlist.remove('btn-light');
            }
          }
          return expand;
        }
        function toggle_expand () {
          var expand = set_expand(null);
          document.cookie = 'perldoc_expand=' + (expand ? 1 : 0) + '; path=/; expires=Tue, 19 Jan 2038 03:14:07 UTC';
        }
        function read_expand () {
          return document.cookie.split(';').some(function (item) { return item.indexOf('perldoc_expand=1') >= 0 });
        }
        if (document.readyState === 'loading') {
          document.addEventListener('DOMContentLoaded', function () {
            if (read_expand()) {
              set_expand(true);
            }
          });
        } else if (read_expand()) {
          set_expand(true);
        }
      </script>
      <button id="content-expand-button" type="button" class="btn btn-outline-light d-none d-lg-inline-block mr-2" onclick="toggle_expand()">Expand</button>
    <ul>
    <form class="form-inline" method="get" action="https://perldoc.perl.org/5.35.0/search">
      <input class="form-control mr-3" type="search" name="q" placeholder="Search" aria-label="Search">
    </form>
  </div>
</nav>

    <div id="wrapperlicious" class="container-fluid">
      <div id="perldocdiv">
        <div id="links">
          <a href="perlpod.html">perlpod</a>
          <div id="more">
            (<a href="perlpod.txt">source</a>,
            <a href="https://metacpan.org/pod/perlpod">CPAN</a>)
          </div>
        </div>
        <div class="leading-notice">
          You are viewing the version of this documentation from Perl 5.35.0.
            This is a development version of Perl.
        </div>
        <h1><a id="toc">CONTENTS</a></h1>
                  <ul>
              <li>
                <a class="text-decoration-none" href="perlpod.html#NAME">NAME  </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#DESCRIPTION">DESCRIPTION</a>
                            <ul>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Ordinary-Paragraph">Ordinary Paragraph </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Verbatim-Paragraph">Verbatim Paragraph  </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Command-Paragraph">Command Paragraph </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Formatting-Codes">Formatting Codes    </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#The-Intent">The Intent </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Embedding-Pods-in-Perl-Modules">Embedding Pods in Perl Modules </a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#Hints-for-Writing-Pod">Hints for Writing Pod</a>
              </li>
          </ul>

              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#SEE-ALSO">SEE ALSO</a>
              </li>
              <li>
                <a class="text-decoration-none" href="perlpod.html#AUTHOR">AUTHOR</a>
              </li>
          </ul>

      <h1 id="NAME"><a class="permalink" href="perlpod.html#NAME">#</a>NAME  </h1>

<p>perlpod - the Plain Old Documentation format</p>

<h1 id="DESCRIPTION"><a class="permalink" href="perlpod.html#DESCRIPTION">#</a>DESCRIPTION</h1>

<p>Pod is a simple-to-use markup language used for writing documentation for Perl, Perl programs, and Perl modules.</p>

<p>Translators are available for converting Pod to various formats like plain text, HTML, man pages, and more.</p>

<p>Pod markup consists of three basic kinds of paragraphs: <a href="perlpod.html#Ordinary-Paragraph">ordinary</a>, <a href="perlpod.html#Verbatim-Paragraph">verbatim</a>, and <a href="perlpod.html#Command-Paragraph">command</a>.</p>

<h2 id="Ordinary-Paragraph"><a class="permalink" href="perlpod.html#Ordinary-Paragraph">#</a><a id="Ordinary"></a>Ordinary Paragraph </h2>

<p>Most paragraphs in your documentation will be ordinary blocks of text, like this one. You can simply type in your text without any markup whatsoever, and with just a blank line before and after. When it gets formatted, it will undergo minimal formatting, like being rewrapped, probably put into a proportionally spaced font, and maybe even justified.</p>

<p>You can use formatting codes in ordinary paragraphs, for <b>bold</b>, <i>italic</i>, <code>code-style</code>, <a href="perlfaq.html">hyperlinks</a>, and more. Such codes are explained in the &quot;<a href="perlpod.html#Formatting-Codes">Formatting Codes</a>&quot; section, below.</p>

<h2 id="Verbatim-Paragraph"><a class="permalink" href="perlpod.html#Verbatim-Paragraph">#</a><a id="Verbatim"></a>Verbatim Paragraph  </h2>

<p>Verbatim paragraphs are usually used for presenting a codeblock or other text which does not require any special parsing or formatting, and which shouldn&#39;t be wrapped.</p>

<p>A verbatim paragraph is distinguished by having its first character be a space or a tab. (And commonly, all its lines begin with spaces and/or tabs.) It should be reproduced exactly, with tabs assumed to be on 8-column boundaries. There are no special formatting codes, so you can&#39;t italicize or anything like that. A \ means \, and nothing else.</p>

<h2 id="Command-Paragraph"><a class="permalink" href="perlpod.html#Command-Paragraph">#</a><a id="Command"></a>Command Paragraph </h2>

<p>A command paragraph is used for special treatment of whole chunks of text, usually as headings or parts of lists.</p>

<p>All command paragraphs (which are typically only one line long) start with &quot;=&quot;, followed by an identifier, followed by arbitrary text that the command can use however it pleases. Currently recognized commands are</p>

<pre><code class="plaintext">=pod
=head1 Heading Text
=head2 Heading Text
=head3 Heading Text
=head4 Heading Text
=over indentlevel
=item stuff
=back
=begin format
=end format
=for format text...
=encoding type
=cut</code></pre>

<p>To explain them each in detail:</p>

<dl>

<dt id="=head1-Heading-Text"><a class="permalink" href="perlpod.html#=head1-Heading-Text">#</a><a id="head1-Heading-Text"></a><code>=head1 <i>Heading Text</i></code>        </dt>
<dd>

</dd>
<dt id="=head2-Heading-Text"><a class="permalink" href="perlpod.html#=head2-Heading-Text">#</a><a id="head2-Heading-Text"></a><code>=head2 <i>Heading Text</i></code></dt>
<dd>

</dd>
<dt id="=head3-Heading-Text"><a class="permalink" href="perlpod.html#=head3-Heading-Text">#</a><a id="head3-Heading-Text"></a><code>=head3 <i>Heading Text</i></code></dt>
<dd>

</dd>
<dt id="=head4-Heading-Text"><a class="permalink" href="perlpod.html#=head4-Heading-Text">#</a><a id="head4-Heading-Text"></a><code>=head4 <i>Heading Text</i></code></dt>
<dd>

<p>Head1 through head4 produce headings, head1 being the highest level. The text in the rest of this paragraph is the content of the heading. For example:</p>

<pre><code class="plaintext">=head2 Object Attributes</code></pre>

<p>The text &quot;Object Attributes&quot; comprises the heading there. The text in these heading commands can use formatting codes, as seen here:</p>

<pre><code class="plaintext">=head2 Possible Values for C&lt;$/&gt;</code></pre>

<p>Such commands are explained in the &quot;<a href="perlpod.html#Formatting-Codes">Formatting Codes</a>&quot; section, below.</p>

</dd>
<dt id="=over-indentlevel"><a class="permalink" href="perlpod.html#=over-indentlevel">#</a><a id="over-indentlevel"></a><code>=over <i>indentlevel</i></code>      </dt>
<dd>

</dd>
<dt id="=item-stuff..."><a class="permalink" href="perlpod.html#=item-stuff...">#</a><a id="item-stuff"></a><code>=item <i>stuff...</i></code></dt>
<dd>

</dd>
<dt id="=back"><a class="permalink" href="perlpod.html#=back">#</a><a id="back"></a><code>=back</code></dt>
<dd>

<p>Item, over, and back require a little more explanation: &quot;=over&quot; starts a region specifically for the generation of a list using &quot;=item&quot; commands, or for indenting (groups of) normal paragraphs. At the end of your list, use &quot;=back&quot; to end it. The <i>indentlevel</i> option to &quot;=over&quot; indicates how far over to indent, generally in ems (where one em is the width of an &quot;M&quot; in the document&#39;s base font) or roughly comparable units; if there is no <i>indentlevel</i> option, it defaults to four. (And some formatters may just ignore whatever <i>indentlevel</i> you provide.) In the <i>stuff</i> in <code>=item <i>stuff...</i></code>, you may use formatting codes, as seen here:</p>

<pre><code class="plaintext">=item Using C&lt;$|&gt; to Control Buffering</code></pre>

<p>Such commands are explained in the &quot;<a href="perlpod.html#Formatting-Codes">Formatting Codes</a>&quot; section, below.</p>

<p>Note also that there are some basic rules to using &quot;=over&quot; ... &quot;=back&quot; regions:</p>

<ul>

<li><p>Don&#39;t use &quot;=item&quot;s outside of an &quot;=over&quot; ... &quot;=back&quot; region.</p>

</li>
<li><p>The first thing after the &quot;=over&quot; command should be an &quot;=item&quot;, unless there aren&#39;t going to be any items at all in this &quot;=over&quot; ... &quot;=back&quot; region.</p>

</li>
<li><p>Don&#39;t put &quot;=head<i>n</i>&quot; commands inside an &quot;=over&quot; ... &quot;=back&quot; region.</p>

</li>
<li><p>And perhaps most importantly, keep the items consistent: either use &quot;=item *&quot; for all of them, to produce bullets; or use &quot;=item 1.&quot;, &quot;=item 2.&quot;, etc., to produce numbered lists; or use &quot;=item foo&quot;, &quot;=item bar&quot;, etc.--namely, things that look nothing like bullets or numbers. (If you have a list that contains both: 1) things that don&#39;t look like bullets nor numbers, plus 2) things that do, you should preface the bullet- or number-like items with <code>Z&lt;&gt;</code>. See <a href="perlpod.html#Z%3C%3E-a-null-%28zero-effect%29-formatting-code">Z&lt;&gt;</a> below for an example.)</p>

<p>If you start with bullets or numbers, stick with them, as formatters use the first &quot;=item&quot; type to decide how to format the list.</p>

</li>
</ul>

</dd>
<dt id="=cut"><a class="permalink" href="perlpod.html#=cut">#</a><a id="cut"></a><code>=cut</code>  </dt>
<dd>

<p>To end a Pod block, use a blank line, then a line beginning with &quot;=cut&quot;, and a blank line after it. This lets Perl (and the Pod formatter) know that this is where Perl code is resuming. (The blank line before the &quot;=cut&quot; is not technically necessary, but many older Pod processors require it.)</p>

</dd>
<dt id="=pod"><a class="permalink" href="perlpod.html#=pod">#</a><a id="pod"></a><code>=pod</code>  </dt>
<dd>

<p>The &quot;=pod&quot; command by itself doesn&#39;t do much of anything, but it signals to Perl (and Pod formatters) that a Pod block starts here. A Pod block starts with <i>any</i> command paragraph, so a &quot;=pod&quot; command is usually used just when you want to start a Pod block with an ordinary paragraph or a verbatim paragraph. For example:</p>

<pre><code>=item stuff()

This function does stuff.

=cut

sub stuff {
  ...
}

=pod

Remember to check its return value, as in:

  stuff() || die &quot;Couldn&#39;t do stuff!&quot;;

=cut</code></pre>

</dd>
<dt id="=begin-formatname"><a class="permalink" href="perlpod.html#=begin-formatname">#</a><a id="begin-formatname"></a><code>=begin <i>formatname</i></code>      </dt>
<dd>

</dd>
<dt id="=end-formatname"><a class="permalink" href="perlpod.html#=end-formatname">#</a><a id="end-formatname"></a><code>=end <i>formatname</i></code></dt>
<dd>

</dd>
<dt id="=for-formatname-text..."><a class="permalink" href="perlpod.html#=for-formatname-text...">#</a><a id="for-formatname-text"></a><code>=for <i>formatname</i> <i>text...</i></code></dt>
<dd>

<p>For, begin, and end will let you have regions of text/code/data that are not generally interpreted as normal Pod text, but are passed directly to particular formatters, or are otherwise special. A formatter that can use that format will use the region, otherwise it will be completely ignored.</p>

<p>A command &quot;=begin <i>formatname</i>&quot;, some paragraphs, and a command &quot;=end <i>formatname</i>&quot;, mean that the text/data in between is meant for formatters that understand the special format called <i>formatname</i>. For example,</p>

<pre><code class="plaintext">=begin html

&lt;hr&gt; &lt;img src=&quot;thang.png&quot;&gt;
&lt;p&gt; This is a raw HTML paragraph &lt;/p&gt;

=end html</code></pre>

<p>The command &quot;=for <i>formatname</i> <i>text...</i>&quot; specifies that the remainder of just this paragraph (starting right after <i>formatname</i>) is in that special format.</p>

<pre><code class="plaintext">=for html &lt;hr&gt; &lt;img src=&quot;thang.png&quot;&gt;
&lt;p&gt; This is a raw HTML paragraph &lt;/p&gt;</code></pre>

<p>This means the same thing as the above &quot;=begin html&quot; ... &quot;=end html&quot; region.</p>

<p>That is, with &quot;=for&quot;, you can have only one paragraph&#39;s worth of text (i.e., the text in &quot;=foo targetname text...&quot;), but with &quot;=begin targetname&quot; ... &quot;=end targetname&quot;, you can have any amount of stuff in between. (Note that there still must be a blank line after the &quot;=begin&quot; command and a blank line before the &quot;=end&quot; command.)</p>

<p>Here are some examples of how to use these:</p>

<pre><code class="plaintext">=begin html

&lt;br&gt;Figure 1.&lt;br&gt;&lt;IMG SRC=&quot;figure1.png&quot;&gt;&lt;br&gt;

=end html

=begin text

  ---------------
  |  foo        |
  |        bar  |
  ---------------

^^^^ Figure 1. ^^^^

=end text</code></pre>

<p>Some format names that formatters currently are known to accept include &quot;roff&quot;, &quot;man&quot;, &quot;latex&quot;, &quot;tex&quot;, &quot;text&quot;, and &quot;html&quot;. (Some formatters will treat some of these as synonyms.)</p>

<p>A format name of &quot;comment&quot; is common for just making notes (presumably to yourself) that won&#39;t appear in any formatted version of the Pod document:</p>

<pre><code class="plaintext">=for comment
Make sure that all the available options are documented!</code></pre>

<p>Some <i>formatnames</i> will require a leading colon (as in <code>&quot;=for :formatname&quot;</code>, or <code>&quot;=begin :formatname&quot; ... &quot;=end :formatname&quot;</code>), to signal that the text is not raw data, but instead <i>is</i> Pod text (i.e., possibly containing formatting codes) that&#39;s just not for normal formatting (e.g., may not be a normal-use paragraph, but might be for formatting as a footnote).</p>

</dd>
<dt id="=encoding-encodingname"><a class="permalink" href="perlpod.html#=encoding-encodingname">#</a><a id="encoding-encodingname"></a><code>=encoding <i>encodingname</i></code>  </dt>
<dd>

<p>This command is used for declaring the encoding of a document. Most users won&#39;t need this; but if your encoding isn&#39;t US-ASCII, then put a <code>=encoding <i>encodingname</i></code> command very early in the document so that pod formatters will know how to decode the document. For <i>encodingname</i>, use a name recognized by the <a href="./Encode::Supported.html">Encode::Supported</a> module. Some pod formatters may try to guess between a Latin-1 or CP-1252 versus UTF-8 encoding, but they may guess wrong. It&#39;s best to be explicit if you use anything besides strict ASCII. Examples:</p>

<pre><code class="plaintext">=encoding latin1

=encoding utf8

=encoding koi8-r

=encoding ShiftJIS

=encoding big5</code></pre>

<p><code>=encoding</code> affects the whole document, and must occur only once.</p>

</dd>
</dl>

<p>And don&#39;t forget, all commands but <code>=encoding</code> last up until the end of its <i>paragraph</i>, not its line. So in the examples below, you can see that every command needs the blank line after it, to end its paragraph. (And some older Pod translators may require the <code>=encoding</code> line to have a following blank line as well, even though it should be legal to omit.)</p>

<p>Some examples of lists include:</p>

<pre><code class="plaintext">=over

=item *

First item

=item *

Second item

=back

=over

=item Foo()

Description of Foo function

=item Bar()

Description of Bar function

=back</code></pre>

<h2 id="Formatting-Codes"><a class="permalink" href="perlpod.html#Formatting-Codes">#</a><a id="Formatting"></a>Formatting Codes    </h2>

<p>In ordinary paragraphs and in some command paragraphs, various formatting codes (a.k.a. &quot;interior sequences&quot;) can be used:</p>

<dl>

<dt id="I-italic-text"><a class="permalink" href="perlpod.html#I-italic-text">#</a><a id="I&lt;text&gt;-italic-text"></a><a id="I"></a><a id="Itext----italic-text"></a><code>I&lt;text&gt;</code> -- italic text    </dt>
<dd>

<p>Used for emphasis (&quot;<code>be I&lt;careful!&gt;</code>&quot;) and parameters (&quot;<code>redo I&lt;LABEL&gt;</code>&quot;)</p>

</dd>
<dt id="B-bold-text"><a class="permalink" href="perlpod.html#B-bold-text">#</a><a id="B&lt;text&gt;-bold-text"></a><a id="B"></a><a id="Btext----bold-text"></a><code>B&lt;text&gt;</code> -- bold text    </dt>
<dd>

<p>Used for switches (&quot;<code>perl&#39;s B&lt;-n&gt; switch</code>&quot;), programs (&quot;<code>some systems provide a B&lt;chfn&gt; for that</code>&quot;), emphasis (&quot;<code>be B&lt;careful!&gt;</code>&quot;), and so on (&quot;<code>and that feature is known as B&lt;autovivification&gt;</code>&quot;).</p>

</dd>
<dt id="C-code-text"><a class="permalink" href="perlpod.html#C-code-text">#</a><a id="C&lt;code&gt;-code-text"></a><a id="C"></a><a id="Ccode----code-text"></a><code>C&lt;code&gt;</code> -- code text    </dt>
<dd>

<p>Renders code in a typewriter font, or gives some other indication that this represents program text (&quot;<code>C&lt;gmtime($^T)&gt;</code>&quot;) or some other form of computerese (&quot;<code>C&lt;drwxr-xr-x&gt;</code>&quot;).</p>

</dd>
<dt id="L-a-hyperlink"><a class="permalink" href="perlpod.html#L-a-hyperlink">#</a><a id="L&lt;name&gt;-a-hyperlink"></a><a id="L"></a><a id="Lname----a-hyperlink"></a><code>L&lt;name&gt;</code> -- a hyperlink    </dt>
<dd>

<p>There are various syntaxes, listed below. In the syntaxes given, <code>text</code>, <code>name</code>, and <code>section</code> cannot contain the characters &#39;/&#39; and &#39;|&#39;; and any &#39;&lt;&#39; or &#39;&gt;&#39; should be matched.</p>

<ul>

<li><p><code>L&lt;name&gt;</code></p>

<p>Link to a Perl manual page (e.g., <code>L&lt;Net::Ping&gt;</code>). Note that <code>name</code> should not contain spaces. This syntax is also occasionally used for references to Unix man pages, as in <code>L&lt;crontab(5)&gt;</code>.</p>

</li>
<li><p><code>L&lt;name/&quot;sec&quot;&gt;</code> or <code>L&lt;name/sec&gt;</code></p>

<p>Link to a section in other manual page. E.g., <code>L&lt;perlsyn/&quot;For Loops&quot;&gt;</code></p>

</li>
<li><p><code>L&lt;/&quot;sec&quot;&gt;</code> or <code>L&lt;/sec&gt;</code></p>

<p>Link to a section in this manual page. E.g., <code>L&lt;/&quot;Object Methods&quot;&gt;</code></p>

</li>
</ul>

<p>A section is started by the named heading or item. For example, <code>L&lt;perlvar/$.&gt;</code> or <code>L&lt;perlvar/&quot;$.&quot;&gt;</code> both link to the section started by &quot;<code>=item $.</code>&quot; in perlvar. And <code>L&lt;perlsyn/For Loops&gt;</code> or <code>L&lt;perlsyn/&quot;For Loops&quot;&gt;</code> both link to the section started by &quot;<code>=head2 For Loops</code>&quot; in perlsyn.</p>

<p>To control what text is used for display, you use &quot;<code>L&lt;text|...&gt;</code>&quot;, as in:</p>

<ul>

<li><p><code>L&lt;text|name&gt;</code></p>

<p>Link this text to that manual page. E.g., <code>L&lt;Perl Error Messages|perldiag&gt;</code></p>

</li>
<li><p><code>L&lt;text|name/&quot;sec&quot;&gt;</code> or <code>L&lt;text|name/sec&gt;</code></p>

<p>Link this text to that section in that manual page. E.g., <code>L&lt;postfix &quot;if&quot;|perlsyn/&quot;Statement Modifiers&quot;&gt;</code></p>

</li>
<li><p><code>L&lt;text|/&quot;sec&quot;&gt;</code> or <code>L&lt;text|/sec&gt;</code> or <code>L&lt;text|&quot;sec&quot;&gt;</code></p>

<p>Link this text to that section in this manual page. E.g., <code>L&lt;the various attributes|/&quot;Member Data&quot;&gt;</code></p>

</li>
</ul>

<p>Or you can link to a web page:</p>

<ul>

<li><p><code>L&lt;scheme:...&gt;</code></p>

<p><code>L&lt;text|scheme:...&gt;</code></p>

<p>Links to an absolute URL. For example, <code>L&lt;http://www.perl.org/&gt;</code> or <code>L&lt;The Perl Home Page|http://www.perl.org/&gt;</code>.</p>

</li>
</ul>

</dd>
<dt id="E-a-character-escape"><a class="permalink" href="perlpod.html#E-a-character-escape">#</a><a id="E&lt;escape&gt;-a-character-escape"></a><a id="E"></a><a id="Eescape----a-character-escape"></a><code>E&lt;escape&gt;</code> -- a character escape    </dt>
<dd>

<p>Very similar to HTML/XML <code>&amp;<i>foo</i>;</code> &quot;entity references&quot;:</p>

<ul>

<li><p><code>E&lt;lt&gt;</code> -- a literal &lt; (less than)</p>

</li>
<li><p><code>E&lt;gt&gt;</code> -- a literal &gt; (greater than)</p>

</li>
<li><p><code>E&lt;verbar&gt;</code> -- a literal | (<i>ver</i>tical <i>bar</i>)</p>

</li>
<li><p><code>E&lt;sol&gt;</code> -- a literal / (<i>sol</i>idus)</p>

<p>The above four are optional except in other formatting codes, notably <code>L&lt;...&gt;</code>, and when preceded by a capital letter.</p>

</li>
<li><p><code>E&lt;htmlname&gt;</code></p>

<p>Some non-numeric HTML entity name, such as <code>E&lt;eacute&gt;</code>, meaning the same thing as <code>&amp;eacute;</code> in HTML -- i.e., a lowercase e with an acute (/-shaped) accent.</p>

</li>
<li><p><code>E&lt;number&gt;</code></p>

<p>The ASCII/Latin-1/Unicode character with that number. A leading &quot;0x&quot; means that <i>number</i> is hex, as in <code>E&lt;0x201E&gt;</code>. A leading &quot;0&quot; means that <i>number</i> is octal, as in <code>E&lt;075&gt;</code>. Otherwise <i>number</i> is interpreted as being in decimal, as in <code>E&lt;181&gt;</code>.</p>

<p>Note that older Pod formatters might not recognize octal or hex numeric escapes, and that many formatters cannot reliably render characters above 255. (Some formatters may even have to use compromised renderings of Latin-1/CP-1252 characters, like rendering <code>E&lt;eacute&gt;</code> as just a plain &quot;e&quot;.)</p>

</li>
</ul>

</dd>
<dt id="F-used-for-filenames"><a class="permalink" href="perlpod.html#F-used-for-filenames">#</a><a id="F&lt;filename&gt;-used-for-filenames"></a><a id="F"></a><a id="Ffilename----used-for-filenames"></a><code>F&lt;filename&gt;</code> -- used for filenames    </dt>
<dd>

<p>Typically displayed in italics. Example: &quot;<code>F&lt;.cshrc&gt;</code>&quot;</p>

</dd>
<dt id="S-text-contains-non-breaking-spaces"><a class="permalink" href="perlpod.html#S-text-contains-non-breaking-spaces">#</a><a id="S&lt;text&gt;-text-contains-non-breaking-spaces"></a><a id="S"></a><a id="Stext----text-contains-non-breaking-spaces"></a><code>S&lt;text&gt;</code> -- text contains non-breaking spaces    </dt>
<dd>

<p>This means that the words in <i>text</i> should not be broken across lines. Example: <span style="white-space: nowrap;"><code>S&lt;$x ? $y : $z&gt;</code></span>.</p>

</dd>
<dt id="X-an-index-entry"><a class="permalink" href="perlpod.html#X-an-index-entry">#</a><a id="X&lt;topic-name&gt;-an-index-entry"></a><a id="X"></a><a id="Xtopic-name----an-index-entry"></a><code>X&lt;topic name&gt;</code> -- an index entry    </dt>
<dd>

<p>This is ignored by most formatters, but some may use it for building indexes. It always renders as empty-string. Example: <code>X&lt;absolutizing relative URLs&gt;</code></p>

</dd>
<dt id="Z&lt;&gt;-a-null-(zero-effect)-formatting-code"><a class="permalink" href="perlpod.html#Z%3C%3E-a-null-(zero-effect)-formatting-code">#</a><a id="Z"></a><a id="Z----a-null-zero-effect-formatting-code"></a><code>Z&lt;&gt;</code> -- a null (zero-effect) formatting code    </dt>
<dd>

<p>This is rarely used. It&#39;s one way to get around using an E&lt;...&gt; code sometimes. For example, instead of &quot;<code>NE&lt;lt&gt;3</code>&quot; (for &quot;N&lt;3&quot;) you could write &quot;<code>NZ&lt;&gt;&lt;3</code>&quot; (the &quot;Z&lt;&gt;&quot; breaks up the &quot;N&quot; and the &quot;&lt;&quot; so they can&#39;t be considered the part of a (fictitious) &quot;N&lt;...&gt;&quot; code).</p>

<p>Another use is to indicate that <i>stuff</i> in <code>=item Z&lt;&gt;<i>stuff...</i></code> is not to be considered to be a bullet or number. For example, without the <code>Z&lt;&gt;</code>, the line</p>

<pre><code class="plaintext">=item Z&lt;&gt;500 Server error</code></pre>

<p>could possibly be parsed as an item in a numbered list when it isn&#39;t meant to be.</p>

<p>Still another use is to maintain visual space between <code>=item</code> lines. If you specify</p>

<pre><code class="plaintext">=item foo

=item bar</code></pre>

<p>it will typically get rendered as</p>

<pre><code class="plaintext">foo
bar</code></pre>

<p>That may be what you want, but if what you really want is</p>

<pre><code class="plaintext">foo

bar</code></pre>

<p>you can use <code>Z&lt;&gt;</code> to accomplish that</p>

<pre><code class="plaintext">=item foo

Z&lt;&gt;

=item bar</code></pre>

</dd>
</dl>

<p>Most of the time, you will need only a single set of angle brackets to delimit the beginning and end of formatting codes. However, sometimes you will want to put a real right angle bracket (a greater-than sign, &#39;&gt;&#39;) inside of a formatting code. This is particularly common when using a formatting code to provide a different font-type for a snippet of code. As with all things in Perl, there is more than one way to do it. One way is to simply escape the closing bracket using an <code>E</code> code:</p>

<pre><code>C&lt;$a E&lt;lt&gt;=E&lt;gt&gt; $b&gt;</code></pre>

<p>This will produce: &quot;<code>$a &lt;=&gt; $b</code>&quot;</p>

<p>A more readable, and perhaps more &quot;plain&quot; way is to use an alternate set of delimiters that doesn&#39;t require a single &quot;&gt;&quot; to be escaped. Doubled angle brackets (&quot;&lt;&lt;&quot; and &quot;&gt;&gt;&quot;) may be used <i>if and only if there is whitespace right after the opening delimiter and whitespace right before the closing delimiter!</i> For example, the following will do the trick: </p>

<pre><code>C&lt;&lt; $a &lt;=&gt; $b &gt;&gt;</code></pre>

<p>In fact, you can use as many repeated angle-brackets as you like so long as you have the same number of them in the opening and closing delimiters, and make sure that whitespace immediately follows the last &#39;&lt;&#39; of the opening delimiter, and immediately precedes the first &#39;&gt;&#39; of the closing delimiter. (The whitespace is ignored.) So the following will also work: </p>

<pre><code>C&lt;&lt;&lt; $a &lt;=&gt; $b &gt;&gt;&gt;
C&lt;&lt;&lt;&lt;  $a &lt;=&gt; $b     &gt;&gt;&gt;&gt;</code></pre>

<p>And they all mean exactly the same as this:</p>

<pre><code>C&lt;$a E&lt;lt&gt;=E&lt;gt&gt; $b&gt;</code></pre>

<p>The multiple-bracket form does not affect the interpretation of the contents of the formatting code, only how it must end. That means that the examples above are also exactly the same as this:</p>

<pre><code>C&lt;&lt; $a E&lt;lt&gt;=E&lt;gt&gt; $b &gt;&gt;</code></pre>

<p>As a further example, this means that if you wanted to put these bits of code in <code>C</code> (code) style:</p>

<pre><code>open(X, &quot;&gt;&gt;thing.dat&quot;) || die $!
$foo-&gt;bar();</code></pre>

<p>you could do it like so:</p>

<pre><code>C&lt;&lt;&lt; open(X, &quot;&gt;&gt;thing.dat&quot;) || die $! &gt;&gt;&gt;
C&lt;&lt; $foo-&gt;bar(); &gt;&gt;</code></pre>

<p>which is presumably easier to read than the old way:</p>

<pre><code>C&lt;open(X, &quot;E&lt;gt&gt;E&lt;gt&gt;thing.dat&quot;) || die $!&gt;
C&lt;$foo-E&lt;gt&gt;bar();&gt;</code></pre>

<p>This is currently supported by pod2text (Pod::Text), pod2man (Pod::Man), and any other pod2xxx or Pod::Xxxx translators that use Pod::Parser 1.093 or later, or Pod::Tree 1.02 or later.</p>

<h2 id="The-Intent"><a class="permalink" href="perlpod.html#The-Intent">#</a><a id="The"></a>The Intent </h2>

<p>The intent is simplicity of use, not power of expression. Paragraphs look like paragraphs (block format), so that they stand out visually, and so that I could run them through <code>fmt</code> easily to reformat them (that&#39;s F7 in my version of <b>vi</b>, or Esc Q in my version of <b>emacs</b>). I wanted the translator to always leave the <code>&#39;</code> and <code>`</code> and <code>&quot;</code> quotes alone, in verbatim mode, so I could slurp in a working program, shift it over four spaces, and have it print out, er, verbatim. And presumably in a monospace font.</p>

<p>The Pod format is not necessarily sufficient for writing a book. Pod is just meant to be an idiot-proof common source for nroff, HTML, TeX, and other markup languages, as used for online documentation. Translators exist for <b>pod2text</b>, <b>pod2html</b>, <b>pod2man</b> (that&#39;s for nroff(1) and troff(1)), <b>pod2latex</b>, and <b>pod2fm</b>. Various others are available in CPAN.</p>

<h2 id="Embedding-Pods-in-Perl-Modules"><a class="permalink" href="perlpod.html#Embedding-Pods-in-Perl-Modules">#</a><a id="Embedding"></a>Embedding Pods in Perl Modules </h2>

<p>You can embed Pod documentation in your Perl modules and scripts. Start your documentation with an empty line, a &quot;=head1&quot; command at the beginning, and end it with a &quot;=cut&quot; command and an empty line. The <b>perl</b> executable will ignore the Pod text. You can place a Pod statement where <b>perl</b> expects the beginning of a new statement, but not within a statement, as that would result in an error. See any of the supplied library modules for examples.</p>

<p>If you&#39;re going to put your Pod at the end of the file, and you&#39;re using an <code>__END__</code> or <code>__DATA__</code> cut mark, make sure to put an empty line there before the first Pod command.</p>

<pre><code class="plaintext">__END__

=head1 NAME

Time::Local - efficiently compute time from local and GMT time</code></pre>

<p>Without that empty line before the &quot;=head1&quot;, many translators wouldn&#39;t have recognized the &quot;=head1&quot; as starting a Pod block.</p>

<h2 id="Hints-for-Writing-Pod"><a class="permalink" href="perlpod.html#Hints-for-Writing-Pod">#</a><a id="Hints"></a>Hints for Writing Pod</h2>

<ul>

<li><p> </p>

<p>The <b>podchecker</b> command is provided for checking Pod syntax for errors and warnings. For example, it checks for completely blank lines in Pod blocks and for unknown commands and formatting codes. You should still also pass your document through one or more translators and proofread the result, or print out the result and proofread that. Some of the problems found may be bugs in the translators, which you may or may not wish to work around.</p>

</li>
<li><p>If you&#39;re more familiar with writing in HTML than with writing in Pod, you can try your hand at writing documentation in simple HTML, and converting it to Pod with the experimental <a href="./Pod::HTML2Pod.html">Pod::HTML2Pod</a> module, (available in CPAN), and looking at the resulting code. The experimental <a href="./Pod::PXML.html">Pod::PXML</a> module in CPAN might also be useful.</p>

</li>
<li><p>Many older Pod translators require the lines before every Pod command and after every Pod command (including &quot;=cut&quot;!) to be a blank line. Having something like this:</p>

<pre><code># - - - - - - - - - - - -
=item $firecracker-&gt;boom()

This noisily detonates the firecracker object.
=cut
sub boom {
...</code></pre>

<p>...will make such Pod translators completely fail to see the Pod block at all.</p>

<p>Instead, have it like this:</p>

<pre><code># - - - - - - - - - - - -

=item $firecracker-&gt;boom()

This noisily detonates the firecracker object.

=cut

sub boom {
...</code></pre>

</li>
<li><p>Some older Pod translators require paragraphs (including command paragraphs like &quot;=head2 Functions&quot;) to be separated by <i>completely</i> empty lines. If you have an apparently empty line with some spaces on it, this might not count as a separator for those translators, and that could cause odd formatting.</p>

</li>
<li><p>Older translators might add wording around an L&lt;&gt; link, so that <code>L&lt;Foo::Bar&gt;</code> may become &quot;the Foo::Bar manpage&quot;, for example. So you shouldn&#39;t write things like <code>the L&lt;foo&gt; documentation</code>, if you want the translated document to read sensibly. Instead, write <code>the L&lt;Foo::Bar|Foo::Bar&gt; documentation</code> or <code>L&lt;the Foo::Bar documentation|Foo::Bar&gt;</code>, to control how the link comes out.</p>

</li>
<li><p>Going past the 70th column in a verbatim block might be ungracefully wrapped by some formatters.</p>

</li>
</ul>

<h1 id="SEE-ALSO"><a class="permalink" href="perlpod.html#SEE-ALSO">#</a><a id="SEE"></a>SEE ALSO</h1>

<p><a href="perlpodspec.html">perlpodspec</a>, <a href="perlsyn.html#PODs%3A-Embedded-Documentation">&quot;PODs: Embedded Documentation&quot; in perlsyn</a>, <a href="perlnewmod.html">perlnewmod</a>, <a href="perldoc.html">perldoc</a>, <a href="pod2html.html">pod2html</a>, <a href="pod2man.html">pod2man</a>, <a href="podchecker.html">podchecker</a>.</p>

<h1 id="AUTHOR"><a class="permalink" href="perlpod.html#AUTHOR">#</a>AUTHOR</h1>

<p>Larry Wall, Sean M. Burke</p>


      </div>
      <div id="footer">
        <p>Perldoc Browser is maintained by Dan Book (<a href="https://metacpan.org/author/DBOOK">DBOOK</a>). Please contact him via the <a href="https://github.com/Grinnz/perldoc-browser/issues">GitHub issue tracker</a> or <a href="mailto:dbook@cpan.org">email</a> regarding any issues with the site itself, search, or rendering of documentation.</p>

<p>The Perl documentation is maintained by the Perl 5 Porters in the development of Perl. Please contact them via the <a href="https://github.com/Perl/perl5/issues">Perl issue tracker</a>, the <a href="https://lists.perl.org/list/perl5-porters.html">mailing list</a>, or <a href="https://kiwiirc.com/client/irc.perl.org/p5p">IRC</a> to report any issues with the contents or format of the documentation.</p>


      </div>
    </div>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.slim.min.js" integrity="sha512-/DXTXr6nQodMUiq+IUJYCt2PPOUjrHJ9wFrqpJ3XkgPNOZVfMok7cRw6CSxyCQxXn6ozlESsSh1/sMCTF1rL/g==" crossorigin="anonymous"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.1/umd/popper.min.js" integrity="sha512-ubuT8Z88WxezgSqf3RLuNi5lmjstiJcyezx34yIU2gAHonIi27Na7atqzUZCOoY4CExaoFumzOsFQ2Ch+I/HCw==" crossorigin="anonymous"></script>
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV" crossorigin="anonymous"></script>
    <script src="../highlight.pack.js"></script>
    <script>hljs.highlightAll();</script>
  </body>
</html>
